package com.example.data_show.controller;

import com.example.data_show.common.Result;
import com.example.data_show.entity.Crop_yield;
import com.example.data_show.entity.Daydate;
import com.example.data_show.service.Crop_yieldService;
import com.example.data_show.service.DaydateService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@RestController
@RequestMapping("/crop_yield")
public class Crop_yieldController {

    @Resource
    private Crop_yieldService cropYieldService;

    @GetMapping("/all")
    public List<Crop_yield> findAll() {
        return cropYieldService.all();
    };
}
